home *** CD-ROM | disk | FTP | other *** search
Text File | 1989-10-02 | 2.5 KB | 79 lines | [TEXT/GEOL] |
- Item 1400316 2-Oct-89 16:42
-
- From: D2086 Efficient Field Svc, C Faith,PRT
-
- To: APPLE.BUGS Apple Bugs Reporting
- MACAPP.TECH$ MACAPP Tech
- MACDTS Macintosh Developer Tech. Supt.
-
- Sub: Yet more {ObjApp} problems!
-
- Yet one more link,
-
- MPW seems to be behaving really strangely.
-
- I have a script called DoMABuild which does this:
-
- # DoMABuild Script
- open {MyOutput}
- echo DoMABuild Parameters "{1}" "{2}" "{3}" "{4}"
- set olddir `directory`
- setdirectory "{SrcApp}"
- execute MABuild "{1}" "{2}" "{3}" "{4}" > Dev:StdOut ≥≥ Dev:StdOut
- setdirectory "{olddir}"
-
- I also placed this line inside the beginning of MABuild.script
- echo MABuild Parameters "{1}" "{2}" "{3}" "{4}"
-
- If I execute this line from the workSheet:
- DoMABuild MyProgram -Sym
-
- I get output of:
- DoMABuild Parameters MyProgram -Sym
- MABuild parameters MyProgram -Sym
-
- followed by normal MABuild stuff.
-
- but if I directly execute the line:
- execute MABuild MyProgram -Sym
-
- I get Output of:
- MABuild Parameters
-
- followed by normal MABuild stuff.
-
- The following seems to be the case. If I use the word execute directly I
- cannot access the parameters inside the executed script. If I use the word
- execute inside a script then I can access the parameters inside the executed
- script.
-
- The problem with this is that there is no way to keep the scope of the script
- global and still use parameters. I need to access variables changed inside a
- script but in order to do that I need to use execute. Execute "executed"
- directly loses the parameters. Thus execute will only be able to be used
- direcly without parameters, an unfortunate turn of events.
-
- I believe that this is a bug! Execute should handle parameters the same way
- whether called directly or from inside a script.
-
- This whole thing means that I have to go about accessing the {SrcApp} and
- {ObjApp} variables in a different way. I have to modify MABuild.script to
- output the results of
- SET SrcApp
- SET ObjApp
- to a file, and then "execute" this file in the global scope. This really seems
- messy. There ought to be a better way to have these values accessible in the
- global scope.
-
- All I really want to be able to do is to run the application that I last built
- from a menu (whether -Sym or not -debug or not etc). Has anyone done this?
-
- All this is with MPW 3.0
-
- Yours,
- Curtis Faith
- Sierra Software Innovations
- (702) 832 - 7789
-
-
-